|
|
In article <3bc31497@news.povray.org> , "Hugo" <hua### [at] post3teledk> wrote:
> I don't know how to solve that.. But sometimes it would also be great to
> convert ISO's to bitmaps so they can be used as heightfields.. I read the
> documentation for POV 3.5 and I only see the possibility of making 255
> slices of an isosurface
What you are looking for is the "function" image type. It turns out that
for some reason it is missing in
<http://www.povray.org/working-docs/id000164.html#6_5_1_5> so no wonder you
didn't find it.
It basically will work like this in a hfield, but to be more precise it will
work everywhere where a image file is allowed:
height_field
{
function 100, 100 { x + y }
}
Note that the hfield will be of 16 bit precision. If you want it to look
less smooth, you have to modify the function, i.e.
height_field
{
function 100, 100 { floor((x + y) * 10) / 10 }
}
will give you a less smooth hfield surface with more visible steps. Note
that this is more useful for a more complicated function. This one is so
simple you will hardly see a difference.
Thorsten
Post a reply to this message
|
|